package com.qf.order.controller;

import com.qf.order.client.StockClient;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.beans.factory.annotation.Value;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RestController;

/**
 * projectName: spring_alibaba
 *
 * @author: 元
 * time: 2021/8/24 0024 20:22
 * description:
 */
@RestController
public class OrderController {

    @Autowired
    private StockClient stockClient;

    @Value("${order.version}")
    private String version;

    @GetMapping("/order/create")
    public String create(){

        return "订单服务创建,"+stockClient.decr()+","+version;

    }
}
